<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>

<title>个人贷款申请信息修改</title>
<span id="navlink">个人贷款申请信息修改</span>
		<script type="text/javascript" src="<%=request.getContextPath()%>/js/credit/creditApplyPersonal.js"></script>
		<script type="text/javascript" src="<%=request.getContextPath()%>/js/common/money2chinese.js"></script>
		<div id="msg"></div>
		<form action="personalEditSave" method="post" id="form">
		<br/>
		<s:div id="left_area">
		<span class="need">*</span>申请单号:<span>RFG</span><s:textfield name="applyid" value="%{creditApplyPersonal.applyid}" cssClass="readonly" readonly="true"/>
		</s:div>
		<div id="top_area">
			<span class="need">*</span><s:label value="申请日期"/><input name="applydate" id="applydate" value="<s:date name="creditApplyPersonal.applydate" format="yyyy-MM-dd"/>" cssClass="readonly" readonly="true"/>
		</div>
		<table class="table_box table_all_border">
			<tr>
    			<th colspan="4" >申请人基本情况</th>
  			</tr>
			<tr>
				<td style="width:25%">姓名：${person.name}</td>
				<td style="width:25%">性别：<s:select list="#{'1':'男','2':'女'}" value="%{person.sex}" headerKey="" headerValue="--------" emptyOption="true" cssClass="readonly" disabled="true"/> </td>
				<td colspan="2">出生年月：
				<s:if test="person==null||person.dateofbirth==null"></s:if><s:else><s:text name="f.date.ymd"><s:param value="person.dateofbirth"/></s:text></s:else></td>
			</tr>
			<tr>
				<td colspan="2">户籍所在地：${person.domicile}</td>
				<td style="width:25%">邮编：${person.domicilezipcode}</td>
				<td style="width:25%">婚姻状况：<s:select list="#{'1':'已婚','2':'未婚','3':'其它'}" headerKey="" headerValue="--------" emptyOption="true" value="%{person.maritalstatus}" cssClass="readonly" disabled="true"/></td>
			</tr>
			<tr>
				<td colspan="2">现居住地址：${person.currentresidentialaddress}</td>
				<td colspan="2">邮编：${person.residentialrezipcode}</td>
			</tr>
			<tr>
				<td colspan="2">证件类型： <s:select list="dcommonList" headerKey="" headerValue="--------" listKey="code" emptyOption="true" listValue="name" value="%{person.certificatetype}" cssClass="readonly" disabled="true"/></td>
				<td colspan="2">证件号码：${person.certificatenumber}</td>
			</tr>
			<tr>
				<td colspan="4">文化程度：<s:select list="culturaList" headerKey="" headerValue="--------" listKey="code" emptyOption="true" listValue="name" value="%{person.culturaldegree}" cssClass="readonly" disabled="true"></s:select></td>
			</tr>
			<tr>
				<td colspan="4">现有住房来源：<s:if test="person.househascredit=='1'">自有有贷:${person.hhcn}平方米； </s:if> <s:if test="person.househasnocredit=='1'">自有无贷: ${person.hncn}平方米； </s:if>
					<s:if test="person.housewithparents!=null">单位宿舍、与父母同住  ；</s:if><s:if test="person.housegrental!=null">租住:月租金 ${person.housegrental}元；</s:if> 
					<s:if test="person.otherhouse!=null">其它</s:if>
					</td>
			</tr>
			<tr>
				<td  colspan="2">工作单位： ${person.workunit}</td>
				<td  colspan="2">单位电话： ${person.unittelephone}</td>
			</tr>
			<tr>
				<td  colspan="2">现单位工作年限：${person.workingyearsnow}年</td>
				<td  colspan="2">前单位工作年限：${person.workingyearsago}年</td>
			</tr>
			<tr>
				<td  colspan="4">职务：${person.post}</td>
			</tr>
			<tr>
				<td colspan="2">所投资或经营企业名称：${person.theinvestmentorbusinessenterprisename}</td>
				<td colspan="2">持股比例：${person.shareholdingratio}%  本行业和相近行业经营年限:${person.industryandsimilaroperatinglifeb}年</td>
			</tr>
			<tr>
				<td colspan="2">单位地址：${person.unitaddress}</td>
				<td>邮编：${person.unitzipcode}</td>
				<td>单位电话：${person.unittelephone}</td>
			</tr>
			<tr>
				<td colspan="2">通信地址：${person.mailingaddress}</td>
				<td>电子邮件：${person.emailb}</td>
				<td>邮编：${person.zipcode}</td>
			</tr>
			<tr>
				<td colspan="2">家庭电话：${person.homephone}</td>
				<td colspan="2">手机：${person.mobilephone}</td>
			</tr>
			<tr>
				<td colspan="2">本笔业务有无其他共同申请人：  <s:if test="person.otherapplicants==1">有</s:if><s:elseif test="person.otherapplicants==2">无</s:elseif></td>
				<td>其他共同申请人姓名：${person.othercommonnameofapplicant}</td>
				<td>与申请人关系 <s:if test="person.relationshipwithapplicant==1">父子</s:if><s:elseif test="person.relationshipwithapplicant==2">母子</s:elseif><s:else>其它</s:else> </td>
			</tr>
		</table>
		<br>

		<table class="table_box table_all_border">
			<tr>
    			<th colspan="4" >申请人配偶情况</th>
  			</tr>
  			<tr>
  				<td style="width:25%">配偶姓名：${person.nameofspouse}</td>
  				<td style="width:25%">配偶性别：<s:select list="#{'1':'男','2':'女'}" value="%{person.sexb}" headerKey="" headerValue="--------" emptyOption="true" cssClass="readonly" disabled="true"/></td>
  				<td colspan="2" >户口所在地：${person.domicileb}</td>
  			</tr>
			<tr>
				<td colspan="2">证件类型：<s:select list="dcommonList" headerKey="" headerValue="--------" listKey="code" emptyOption="true" listValue="name" value="%{person.certificatetypeb}" cssClass="readonly" disabled="true"/></td>
				<td colspan="2">证件号码：${person.certificatenumberb}</td>
			</tr>
			<tr>
				<td colspan="2">文化程度 ：<s:select list="culturaList" headerKey="" headerValue="--------" listKey="code" emptyOption="true" listValue="name" value="%{person.culturaldegreeb}" cssClass="readonly" disabled="true"></s:select></td>
				<td colspan="2">本地居住年限：${person.localresidence}年</td>
			</tr>
			<tr>
				<td colspan="2">工作单位：${person.workunitb}</td>
				<td style="width:25%">单位电话：${person.unittelephoneb}</td>
				<td style="width:25%">现单位工作年限：${person.workingyearsnowb}年</td>
			</tr>
			<tr>
				<td colspan="3">电子邮件：${person.emailb}</td>
				<td >前单位工作年限：${person.workingyearsagob} 年</td>
			</tr>
			<tr>
				<td colspan="4">职务：${person.postb}</td>
			</tr>
			<tr>
				<td colspan="2">所投资或经营企业名称：${person.theinvestmentorbusinessenterprisenameb}</td>
				<td >持股比例：${person.shareholdingratiob}% </td>
				<td >本行业和相近行业经营年限：${person.industryandsimilaroperatinglife}年</td>
			</tr>
			<tr>
				<td colspan="2">单位地址：${person.unitaddressb}</td>
				<td>邮编：${person.zipcodeb}</td>
				<td>手机：${person.mobilephoneb}</td>
			</tr>
		</table>
		<br>
		<table class="table_box table_all_border">
			<tr>
				<th colspan="12" >申请人家庭收支情况</th>
			</tr>
			<tr>
				<td style="width:25%" colspan="3" >家庭月总收入：
				<s:if test="person==null||person.totalfamilyincome==null"></s:if><s:else><s:text name="f.money"><s:param value="person.totalfamilyincome"/></s:text></s:else>(元)</td>
				<td style="width:25%" colspan="3" >申请人月薪金收入：
				<s:if test="person==null||person.applicantsalaryincome==null"></s:if><s:else><s:text name="f.money"><s:param value="person.applicantsalaryincome"/></s:text></s:else>(元)</td>
				<td style="width:25%" colspan="3" >家庭供养人口：${person.familydependents}人</td>
				<td style="width:25%" colspan="3" >月经营性收入：
				<s:if test="person==null||person.monthlyoperatingincomeb==null"></s:if><s:else><s:text name="f.money"><s:param value="person.monthlyoperatingincomeb"/></s:text></s:else>(元)</td>
			</tr>
			<tr>
				<td colspan="12" >其他经营月收入：
				<s:if test="person==null||person.otheroperatingincome==null"></s:if><s:else><s:text name="f.money"><s:param value="person.otheroperatingincome"/></s:text></s:else>(元)</td>
			</tr>
			<tr>
				<td colspan="4" >申请人配偶月薪金收入：
				<s:if test="person==null||person.spousemonthlyincome==null"></s:if><s:else><s:text name="f.money"><s:param value="person.spousemonthlyincome"/></s:text></s:else>(元)</td>
				<td colspan="4" >月经营性收入：
				<s:if test="person==null||person.monthlyoperatingincome==null"></s:if><s:else><s:text name="f.money"><s:param value="person.monthlyoperatingincome"/></s:text></s:else>(元)</td>
				<td colspan="4" >家庭月债务总支出：
				<s:if test="person==null||person.householddebtexpenditure==null"></s:if><s:else><s:text name="f.money"><s:param value="person.householddebtexpenditure"/></s:text></s:else>(元)</td>
			</tr>
			<tr>
				<td colspan="4" >申请人月还贷款支出：
				<s:if test="person==null||person.applicantontheloanexpenditure==null"></s:if><s:else><s:text name="f.money"><s:param value="person.applicantontheloanexpenditure"/></s:text></s:else>(元)</td>
				<td colspan="4" >申请人配偶月还贷支出：
				<s:if test="person==null||person.spousemonthlyloanpayments==null"></s:if><s:else><s:text name="f.money"><s:param value="person.spousemonthlyloanpayments"/></s:text></s:else>(元)</td>
				<td colspan="4" >家庭对外担保总额：
				<s:if test="person==null||person.totalamountoffamilyguarantee==null"></s:if><s:else><s:text name="f.money"><s:param value="person.totalamountoffamilyguarantee"/></s:text></s:else>(元)</td>
			</tr>
		</table>
		<br>
	<table class="table_box table_all_border" id="applytable">
				<tr>
    				<th colspan="2" >申请贷款情况</th>
  				</tr>
				<tr>
					<th style="width:25%" ><span class="need">*</span>贷款用途</th>
					<td ><s:textfield name="loanuse" id="loanuse"
					value="%{creditApplyPersonal.loanuse}" size="60" /></td>
				</tr>
				<tr>
					<th>贷款品种</th>
					<td ><s:textfield name="loanvarietie" id="loanvarietie" value="%{creditApplyPersonal.loanvarietie}" size="60"/></td>
				</tr>
				<tr>
					<th><span class="need">*</span>贷款金额</th>
					<td >￥<s:textfield name="loanaccount" id="loanaccount" value="%{creditApplyPersonal.loanaccount}" size="30"/>元
					大写金额:RMB<s:textfield name="bigLoanAccount" id="bigLoanAccount" value="" size="55" readonly="true"/>元</td>
				</tr>
				<tr>
					<th><span class="need">*</span>贷款方式 </th>
					<td><s:checkboxlist list="loantypeList" listKey="type" listValue="typename" name="loanofmode" value="%{#request.lomList}" id="loanofmode"/></td>
					</tr>
				<tr>
					<th><span class="need">*</span>是否涉农</th>
					<td><s:radio id="isAboutN" name="isAboutN" list="%{#{'1':'是','0':'否'}}" value="%{creditApplyPersonal.isAboutN}"/></td>
			</tr>
				<tr>
					<th><span class="need">*</span>贷款期限</th>
					<td><s:textfield name="applytime" value="%{creditApplyPersonal.applytime}"/>
						<s:radio id="applytimetype" name="applytimetype" list="%{#{'年':'年','月':'月','天':'天'}}" value="%{creditApplyPersonal.applytimetype}"/>
						<%--<s:select name="creditApplyPersonal.applytimetype" headerKey="" headerValue="----"
						list="#{'年':'年','月':'月','天':'天' }" cssClass="readonly" value="%{creditApplyPersonal.applytimetype}"/> --%>
					</td>
					<%--<td><s:textfield name="applyyear" value="%{person.applyyear}"/>年<s:textfield name="applymonth" value="%{person.applymonth}"/>月<s:textfield name="applyday" value="%{person.applyday}"/>天</td>
				--%>
				</tr>
				<tr>
					<th><span class="need">*</span>还款方式</th>
					<td>
						<s:radio name="modeofrepayment" list="%{#{'3':'按约还息一次性成本','4':'利随本清','5':'等额本金','6':'等额本息 ','7':'其他 '}}" value="%{creditApplyPersonal.modeofrepayment}"></s:radio>
					</td>
				</tr>
				<tr>
					<th></th><td>其中保证贷款金额：
					<s:if test="person==null||person.amountofguaranteeloans==null"></s:if><s:else><s:text name="f.money"><s:param value="creditApplyPersonal.amountofguaranteeloans"/></s:text></s:else>(元)
						信用贷款金额：
						<s:if test="person==null||person.creditloanamount==null"></s:if><s:else><s:text name="f.money"><s:param value="creditApplyPersonal.creditloanamount"/></s:text></s:else>(元)
						贷款尚存金额：
						<s:if test="person==null||person.remainingbalanceofloan==null"></s:if><s:else><s:text name="f.money"><s:param value="creditApplyPersonal.remainingbalanceofloan"/></s:text></s:else>(元)
				</tr>
				
				<tr>
					<th></th>
					<td>
					原银行贷款:	
					<s:if test="person==null||person.originalbankloans==null"></s:if><s:else><s:text name="f.money"><s:param value="creditApplyPersonal.originalbankloans"/></s:text></s:else>(元)
					贷款初始金额:
					<s:if test="person==null||person.initialamountofloan==null"></s:if><s:else><s:text name="f.money"><s:param value="creditApplyPersonal.initialamountofloan"/></s:text></s:else>(元)
					</td>
				</tr>
			</table>
			<br>
			<table class="table_box table_all_border" id="keepInfor1">
					<tr>
						<th colspan="6">担保情况表</th>
					</tr>
				</table>
				
				<s:div style="display:none" id="infor1">
		<br>
		<hr>
		<br>
		<table class="table_box table_all_border" id="hypothecate">
			<tr>
				<th>抵押信息</th>
				<th colspan="5"><input type="button" id="addHypothecate"
					value="增加抵押信息" /></th>
			</tr>
			<s:iterator value="hypothecateList" status="index" var="var">
			<tr>
				<th style="width:25%">抵押人（全称）</th><td colspan="5" style="width:75%"> ${peopleName }</td></tr><tr><th style="width:25%">主要抵押物名称</th><td colspan="2" style="width:25%">${thingName }</td><th style="width:5%">现值</th><td style="width:40%">${price }</td><td style="width:5%"><input type="button" value="删除" onClick="getDel(this)"/></td>
			</tr> 
			<tr>
				<th style="width:25%"></th><th colspan="5" style="width:75%" align="left">物品编号:<input type="text" readOnly="readOnly" name="hypothecateHidden" value="${id }">抵押人编号:<input type="text" name="hypothecateHiddenPI" readOnly="readOnly" value="${peopleid }">关系人类型:<s:if test="relationpeopletype==1"><input type="text" name="hypothecateHiddenRPT" readonly="readonly" value="个人"></s:if><s:elseif test="relationpeopletype==2"><input type="text" name="hypothecateHiddenRPT" readonly="readonly" value="企业"></s:elseif> </th>
			</tr>
			</s:iterator>
		</table>
	</s:div>
	<s:div style="display:none;" id="infor2">
		<br>
		<hr>
		<br>
		<table class="table_box table_all_border" id="pledge">
			<tr>
				<th>质押信息</th>
				<th colspan="5"><input type="button" id="addPledge"
					value="增加质押信息" /></th>
			</tr>
			<s:iterator value="pledgeList" status="index" var="var">
			<tr>
				<th style="width:25%">质押人（全称）</th><td colspan="5" style="width:75%"> ${peopleName }</td></tr><tr><th style="width:25%">主要抵押物名称</th><td colspan="2" style="width:25%">${thingName }</td><th style="width:5%">现值</th><td style="width:40%">${price }</td><td style="width:5%"><input type="button" value="删除" onClick="getDel(this)"/></td>
			</tr> 
			<tr>
				<th style="width:25%"></th><th colspan="5" style="width:75%" align="left">物品编号:<input type="text" readOnly="readOnly" name="hypothecateHidden" value="${id }">质押人编号:<input type="text" name="hypothecateHiddenPI" readOnly="readOnly" value="${peopleid }">关系人类型:<s:if test="relationpeopletype==1"><input type="text" name="hypothecateHiddenRPT" readonly="readonly" value="个人"></s:if><s:elseif test="relationpeopletype==2"><input type="text" name="hypothecateHiddenRPT" readonly="readonly" value="企业"></s:elseif> </th>
			</tr>
			</s:iterator>
		</table>
	</s:div>
	<s:div style="display:none;" id="infor3">
		<br>
		<hr>
		<br>
		<table class="table_box table_all_border" id="keepInfor">
			<tr>
				<th>保证信息</th>
				<th colspan="5"><input type="button" id="addKeepInfor"
					value="增加保证信息" /></th>
			</tr>
			<s:iterator value="enssuerList" status="index" var="var">
			<tr>
				<th style="width:25%">保证人（全称）</th><td colspan="5" style="width:75%">${peopleName }</td></tr><tr><th style="width:25%">基本账户开户行</th><th style="width:10%">本币</th><td style="width:25%">${basicBank }</td><th style="width:10%">外币</th><td style="width:25%">${foreginBank }</td><td style="width:5%"><input type="button" value="删除" onClick="getDel(this)"/></td>
			</tr>
			<tr>
				<th style="width:25%"></th><th style="width:10%">保证人编号：</th><td style="width:25%"><input type="text" name="keepInforHidden" readOnly="readOnly" value="${peopleId }"></td><th style="width:10%">关系人类型：</th><td><s:if test="relationpeopletype==1"><input type="text" name="pledgeHiddenRPT" readonly="readonly" value="个人"></s:if><s:elseif test="relationpeopletype==2"><input type="text" name="keepInforHiddenRPT" readonly="readonly" value="企业"></s:elseif> </td>
			</tr>
			</s:iterator>
		</table>
	</s:div>
			<br>
		<div id="button_area">
				<input type="submit" id="submit" value="提交" />
				<s:reset value="重置"></s:reset>
				 <%--<input type="button" value="取消" />
			--%></div>
</form>
<script type="text/javascript">
<!--
	//alert($("#loanofmode"));
//-->
</script>